package com.bt.lms.ui.action.school_education.query_details;

import com.bt.lms.ui.page.school_education.query_details.PageCheckChangeMes;
import com.bt.lms.ui.page.school_education.query_details.PageCheckManage;
import javafx.collections.ObservableList;
import javafx.event.Event;
import javafx.event.EventHandler;
import javafx.scene.Node;
import javafx.scene.control.Label;
import javafx.scene.layout.HBox;

/**
 *
 * 学籍异动按钮事件
 */
public class QueryChangeMesAction implements EventHandler {


    private PageCheckManage pageCheckManage;

    public QueryChangeMesAction(PageCheckManage pageCheckManage) {
        this.pageCheckManage = pageCheckManage;

    }

    @Override
    public void handle(Event event) {
        //获取里边有几个盒子
        ObservableList<Node> children = pageCheckManage.getChildren();

        HBox hBox = (HBox) children.get(0);
        ObservableList<Node> hBoxChildren = hBox.getChildren();
        hBoxChildren.remove(3);
        Label label = new Label("学籍异动信息");
        hBoxChildren.add(label);

        PageCheckChangeMes pageCheckChangeMes = new PageCheckChangeMes(pageCheckManage);
        children.set(2,pageCheckChangeMes);





    }
}
